package com.lcke.common.except;

public class OperateException extends RuntimeException {

    private Integer code;
    private String errorMessage;

    public OperateException() {
        super("操作异常！");
        this.code = 1501;
        this.errorMessage = "操作异常！";
    }

    public OperateException(Integer code, String errorMessage) {
        super("操作异常！");
        this.code = code;
        this.errorMessage = errorMessage;
    }

    public OperateException(String errorMessage) {
        super("操作异常！" + errorMessage);
        this.code = 1501;
        this.errorMessage = errorMessage;
    }

    public Integer getCode() {
        return code;
    }

    public void setCode(Integer code) {
        this.code = code;
    }

    public String getErrorMessage() {
        return errorMessage;
    }

    public void setErrorMessage(String errorMessage) {
        this.errorMessage = errorMessage;
    }
}
